<?php
/*
 * 手机客户端店铺-检查店铺是否存在接口
 * 2014-03-14
 * 2014-05-08 (已查)
 */
include "inc/public_header.php";


$reJson = array(); //构建返回值

$goodsId = $_REQUEST["goodsId"];

$reJson["success"] = "1";

$sql = "select b.shop_id,b.shop_name from shop_product a INNER JOIN shop_info b on a.shop_id=b.shop_id where a.product_id='".$goodsId."'"; 
$db->query($sql);
if($db->next_record()){
	$shop_id		= $db->f("shop_id");
	$shop_name 		= $db->f("shop_name");
}
$reJson["shopId"] = $shop_id;
$reJson["title"] = $shop_name;

echo json_encode($reJson);
?>
